package com.fy.market.strategy.model.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.math.BigDecimal;
import java.sql.Timestamp;
import java.util.Date;
import java.util.List;

/**
 * 策略奖品规则实体
 *
 * @auth : fwq
 * @date : 2025-09-26
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@Builder
public class StrategyAwardRuleEntity implements Serializable {

    /**
     * 抽奖策略ID
     */
    private Integer strategyId;

    /**
     * 策略奖品ID【规则类型为策略，则不需要奖品ID】
     */
    private Integer strategyAwardId;

    /**
     * 规则模型ID
     */
    private Integer ruleModelId;

    /**
     * 抽奖奖品ID
     */
    private Integer awardId;
    /**
     * 奖品KEY
     */
    @TableField("award_key")
    private String awardKey;
    /**
     * 奖品配置
     */
    @TableField("award_config")
    private String awardConfig;
    /**
     * 奖品描述
     */
    @TableField("award_desc")
    private String awardDesc;
    /**
     * 奖品库存总量
     */
    private Integer awardCount;
    /**
     * 奖品库存剩余
     */
    private Integer awardCountSurplus;
    /**
     * 奖品中奖概率
     */
    private BigDecimal awardRate;

    /**
     * 抽奖奖品标题
     */
    private String awardTitle;
    /**
     * 抽奖奖品副标题
     */
    private String awardSubtitle;
    /**
     * 规则模型
     */
    private List<RuleModelEntity> ruleModels;

    /**
     * 解锁次数
     */
    @TableField(value = "award_unlock_count")
    private Integer awardUnlockCount;

}
